package com.yaodian100.ec.memberevent.entity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.yaodian100.core.common.entity.BaseEntity;

/**
 * 
 * @author apple.chang
 * 
 */
@Entity
@Table(name = "EC_MEMBERGIFT")
public class MemberGift extends BaseEntity {

	/**
	 * 
	 */
	private static final long serialVersionUID = 765451031768707451L;

	@Id
	@GeneratedValue(strategy = GenerationType.AUTO, generator = "seq_ec_membergift")
	@SequenceGenerator(name = "seq_ec_membergift", sequenceName = "SEQ_EC_MEMBERGIFT")
	@Column(name = "ID", length = 10, nullable = false)
	private String id;

	/**
	 * 活动名称
	 */
	@Column(name = "NAME", length = 100, nullable = false)
	private String name;

	/**
	 * 活动说明
	 */
	@Column(name = "MEMO", length = 100, nullable = false)
	private String memo;

	/**
	 * 来源渠道代码
	 */
	@Column(name = "APPLY_SOURCE", length = 50, nullable = false)
	private String applySource;

	/**
	 * 1:赠品 2:特惠商品 3:站内活动
	 */
	@Column(name = "TYPE", length = 1, nullable = false)
	private String type;

	/**
	 * 活动设定值（储存商品编号／活动目的网址）
	 */
	@Column(name = "CONTENT", length = 100, nullable = false)
	private String content;

	/**
	 * 活动图档连结
	 */
	@Column(name = "IMG_PATH", length = 100)
	private String img_path;

	/**
	 * 活动起始日期
	 */
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "START_DATE")
	private Date startDate;

	/**
	 * 活动结束日期
	 */
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "END_DATE")
	private Date endDate;

	/**
	 * 启用否
	 */
	@Column(name = "IS_ACTIVATE", length = 1, nullable = false)
	private String is_activate;

	public MemberGift() {
		super();
	}

	/**
	 * @return the applySource
	 */
	public String getApplySource() {
		return applySource;
	}

	/**
	 * @param applySource the applySource to set
	 */
	public void setApplySource(String applySource) {
		this.applySource = applySource;
	}

	/**
	 * @return the type
	 */
	public String getType() {
		return type;
	}

	/**
	 * @param type the type to set
	 */
	public void setType(String type) {
		this.type = type;
	}

	/**
	 * @return the startDate
	 */
	public Date getStartDate() {
		return startDate;
	}

	/**
	 * @param startDate the startDate to set
	 */
	public void setStartDate(Date startDate) {
		this.startDate = startDate;
	}

	/**
	 * @return the memo
	 */
	public String getMemo() {
		return memo;
	}

	/**
	 * @param memo the memo to set
	 */
	public void setMemo(String memo) {
		this.memo = memo;
	}

	/**
	 * @return the id
	 */
	public String getId() {
		return id;
	}

	/**
	 * @return the endDate
	 */
	public Date getEndDate() {
		return endDate;
	}

	/**
	 * @param endDate the endDate to set
	 */
	public void setEndDate(Date endDate) {
		this.endDate = endDate;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getImg_path() {
		return img_path;
	}

	public void setImg_path(String imgPath) {
		img_path = imgPath;
	}

	public String getIs_activate() {
		return is_activate;
	}

	public void setIs_activate(String isActivate) {
		is_activate = isActivate;
	}

}